<table width="100%" border="0" cellpadding="0" cellspacing="0" style="margin-top:2px; margin-bottom:2px">
	<tr>
		<td id="content-header-left" align="center" >Select categeory</td>
		<td  id='content-header-center' align='center'>Videos</td>
		<td id="content-header-right" ></td>
	</tr>	
	<tr>
		<td id="gossip_left_right" bgcolor="#E3E1E2" valign="top"> 
		<table>
		   <?foreach ($videocategeories->result() as $item) {?>
		   
		     <tr>
		       <td><img src="<?=base_url();?>assets/imgs/button-img.gif" /></td>
			   		
			 <td class="sidelinks"><a href="<?=base_url();?>videos/displayvideos/<?=$item->id?>"><?=ucfirst(trim_name($item->name,15))?></a></td>
				</tr>
			<?} ?>
		     
		  </table>

		</td>
		     
		 	
		  <td valign="top">
		   
			   <table border="0"  bgcolor="#FFF8E5" width="100%" height="100%" style="padding-left:4px; padding-right:4px;">
			   
			       <tr>
			       
			        <td  valign="top" colspan="3" style="height:24px;color:white;font-weight:bold;" align="right">
			  		<div id='pagination' style="text-align:left">
			  		<?//in case of search results do not display sort by days
			  		if ((!isset($search)))
			  		{?>
			  		<a href="<?=base_url();?>videos/displayvideos">Sort New</a>
			  		
			  		<a href="<?=base_url();?>videos/displayvideos/0/7">7days</a>
			  		<a href="<?=base_url();?>videos/displayvideos/0/15">15days</a>
			  		<a href="<?=base_url();?>videos/displayvideos/0/30">1month</a>
			  		<a href="<?=base_url();?>videos/displayvideos/0/90">3months</a>
			  		<a href="<?=base_url();?>videos/displayvideos">All Videos</a>
			  		
			  		<?} else{?>
			  		<a href="<?=base_url();?>videos/displayvideos">Go to All Videos</a><?} ?>
			  		<form action="<?=base_url()?>videos/display" method='post'>
			  		<span style="padding-left:0px;float:right;position:relative;top:-15px"><input style="border:0px;" type="text" name="search" value='search videos' onclick="this.value=''" /><input type='image' src="<?=base_url();?>assets/imgs/search.gif"/></span></form>
			       </div>
			        </td>
			        
			       </tr>
			       <tr>
			       <? 
                        if(($recentvideos->num_rows() == 0 ))
		           {   echo"<td style='text-align:center' width='600px'>";
		              	echo" <h1>No Results to display</h1></td>";
		            }
			       else{
			       $i=1; foreach ($recentvideos->result() as $item) {?>
			       
			         <td width='200px'><div align="center" id="text"><?=ucfirst(trim_name($item->name,20))?><br><div style="padding:0px 25px 0px 25px; height:139px;"><div style="height:104px;margin-top:5px;"><div id="video_time_inner"><? echo $item->time;?></div><a href="<?=base_url();?>video/playvideo/<?=$item->id?>/<?=$item->video_cat_id?>"><img src="<?=base_url();?>assets/videos/image_preview/image<?=$item->id?>_thumb.jpg" border="0px" style="z-index:-2;padding-top:10px"/></a></div></div><div id="text-vi" style="background-color:#FF6407">Time:<?=$item->time?> Views:<?=$item->no_of_views?></div></div> </td>
			        
			       <? 
			       
			      
			       
			       if($i%3==0)
			       {
			       	   echo"</tr><tr>";
			       }
                     $i++;  }?>
                    </tr>
                      
			        <tr style="height:22px;">
			          
			          <td colspan="3" align="center" bgcolor="#CCC7CB" style="color:#F26900;font-size:12px;font-weight:bold;"><? echo $paginate;?></td>
			         <? } ?>
			        </tr>
			   </table>	   
			    
			</td>
		<td id="gossip_left_right" bgcolor="#707070">
		
		<!-- Begin: AdBrite, Generated: 2009-06-16 5:48:41  -->
<script type="text/javascript">
var AdBrite_Title_Color = 'E1771E';
var AdBrite_Text_Color = '000000';
var AdBrite_Background_Color = 'FFFFFF';
var AdBrite_Border_Color = 'FFCC66';
var AdBrite_URL_Color = '008000';
try{var AdBrite_Iframe=window.top!=window.self?2:1;var AdBrite_Referrer=document.referrer==''?document.location:document.referrer;AdBrite_Referrer=encodeURIComponent(AdBrite_Referrer);}catch(e){var AdBrite_Iframe='';var AdBrite_Referrer='';}
</script>
<script type="text/javascript">document.write(String.fromCharCode(60,83,67,82,73,80,84));document.write(' src="http://ads.adbrite.com/mb/text_group.php?sid=1219263&zs=3132305f363030&ifr='+AdBrite_Iframe+'&ref='+AdBrite_Referrer+'" type="text/javascript">');document.write(String.fromCharCode(60,47,83,67,82,73,80,84,62));</script>
<div><a target="_top" href="http://www.adbrite.com/mb/commerce/purchase_form.php?opid=1219263&afsid=1" style="font-weight:bold;font-family:Arial;font-size:13px;">Your Ad Here</a></div>
<!-- End: AdBrite -->
		</td>
	</tr>

</table>